package org.sk.gsync.ui;

import javax.swing.JPanel;

import org.sk.gsync.ui.context.AbstractContext;
import org.sk.gsync.ui.context.DefaultContext;

public abstract class DefaultPanel extends JPanel {

    private static final long serialVersionUID = -8299725420056867973L;

    protected AbstractContext context;

    public AbstractContext getContext() {
        if (context == null) {
            context = new DefaultContext();
        }
        return context;
    }

    protected void setContext(final AbstractContext context) {
        this.context = context;
    }

    public abstract void configure();

    public abstract void updateContext();

}
